package tc.jv.task5;

import java.util.Iterator;

import tc.jv.task4.Vector;

public class Main
{

	public static void main(String[] args)
	{
		
		ArrayVector a = new ArrayVector(3);
		a.set(0, 1.);
		a.set(1, 2.);
		a.set(2, 3.);
		a.print(1);
		
		double[] dbl = new double[] {1., 2., 3.};
		ArrayVector av = new ArrayVector(dbl);
		av.print(1);
		av.set(0, 10.);
		av.print(1);
		System.out.println(dbl[0]);

		for (Iterator<Double> iterator = a.iterator(); iterator.hasNext();)
		{
			iterator.remove();
			a.print(1);
		}
		
		for (Double d : a)
		{
			System.out.println(d);
		}
		
		LinkedListVector ll = new LinkedListVector();
		ll.add(1.);
		ll.add(2.);
		ll.add(3.);
		
		for (Double d : ll)
			System.out.println(d);
				
		
		Vector l = Vectors.generateRandomVector(5, 1, 3);
		l.print(1);
	}

}
